<?php

define('DB_FETCH_ASSOC', 1);
define('DB_FETCH_NUM', 2);

interface iQuery
{
   public function prepare($sql);
   public function setParam($nm, $val);
   public function clearParams();
   public function execute();
   public function exec($sql);
   public function fetch($type=DB_FETCH_NUM);
   public function restart();
   public function at($fnm);   //$fnm can also be 0-indexed field number
   public function eof();
   public function processedCount();
   public function close();
};

interface iDatabase
{
	public function lastInsertId($seqName=null);
	public function quote($s);
};

?>